<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html lang="en" class="no-js"> <!--<![endif]-->
<head>
<meta charset="utf-8" />
<title><?php echo ($title); ?>_<?php echo ($name); ?></title>

 <!-- 导航菜单开始 -->
 <meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta content="width=device-width, initial-scale=1.0" name="viewport" />
<meta content="{key}" name="description" />
<meta content="{des}" name="author" />
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="<?php echo (TEMPS); ?>/css/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css"/>
<link href="<?php echo (TEMPS); ?>/css/font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css"/>
<link href="<?php echo (TEMPS); ?>/css/css.css" rel="stylesheet" type="text/css"/>
<script src="__ROOT__/Public/js/jquery.js"></script>
<script src="__ROOT__/Public/js/bootstrap.min.js"></script>
<link rel="stylesheet" href="__ROOT__/Public/css/yuwei.css">
<link rel="stylesheet" href="<?php echo (TEMPS); ?>/css/common.css">
<script type="text/javascript" src="<?php echo (TEMPS); ?>/js/common.js"></script>
</head>
<body>
<!-- 头部开始 -->
<div class="headerLine"></div>
    <header>
    	<div class="header">
	    	<div class="left">
	    		<span>订餐热线 :<b>13879144915</b> </span>
	    		<span>服务时间 :<b>08:00-17:00</b> </span>
	    	</div>
	    	<div class="right">
<!-- 判断,如果用户uid存在,就说么已经登陆 -->
<?php if(empty($uid)): ?><a href="<?php echo U('Public/register/');?>" rel="nofollow">注册</a>
<a rel="nofollow" href="/index.php?m=public&a=login" >登录</a>
<a href="<?php echo U('Member/index/');?>" rel="nofollow">我的外卖</a>
<?php else: ?>    
<a href="<?php echo U('Member/index/');?>"><i class="fa fa-user-md"></i> <?php if(empty($nickname)): echo ($username); else: echo ($nickname); endif; ?></a></li>
<a href="<?php echo U('Member/order/');?>" rel="nofollow"><i class="fa fa-list"></i> 我的外卖</a>
<a href="<?php echo U('Public/logout/');?>" rel="nofollow"><i class="fa fa-power-off"></i> 退出</a><?php endif; ?>
    	</div>
    </header>
 <!-- 头部结束 -->
<nav class="navbar bs-docs-nav" role="navigation"> 
<div class="navhead w120">
	<ul class="nav navbar-nav ulpast">
      <li><a href="./">网站首页</a></li>
	  <li><a href="<?php echo U('Gift/index/');?>">礼品兑换</a></li>
	  <li><a href="<?php echo U('List/index/',array('id'=>19));?>">今日推荐</a></li>
     	<?php if(empty($uid)): ?><li><a href="<?php echo U('Members/index/');?>">订单管理</a></li>
			<?php else: ?> 
			<li><a href="<?php echo U('Member/order/');?>">我的订单</a></li><?php endif; ?>
	  <li><a href="<?php echo U('Article/s/',array('id'=>37));?>">关于我们</a></li>
	  <li><a href="<?php echo U('Article/s/',array('id'=>31));?>">联系我们</a></li>
	  <li><a href="<?php echo U('Article/s/',array('id'=>36));?>">服务宗旨</a></li>
	  <li><a href="<?php echo U('Message/index/');?>">给我留言</a></li>
	   <div class="lines">
	   	<span class="hover">1</span>
	   </div>
    </ul>
 </div>
  </div><!-- /.navbar-collapse -->
</nav>
<script type="text/javascript">
	$(document).ready(function() {
		lens =$('.ulpast').find('li').length;
		$('.ulpast').find('li').hover(function() {
			w = $(this).width();
			z = $(this).index();
			$('.lines .hover').stop().animate({left: w*z}, 500)
		}, function() {
			
		});
	});
</script>
 <!-- 全局左侧导航菜单 -->
  <div class="col-md-2 hidden-xs" id="menus" style='width:180px'> 
	<img width='150' src='<?php echo (TEMPS); ?>/images/doctor.png' style='z-index:999;position:relative;top:5px;'>
     <ul class="list-unstyled left-border" style="position:relative">
     <div class="topicon" style="text-align:center">
     	
     </div>
      <?php if(is_array($foodcatlist)): $i = 0; $__LIST__ = array_slice($foodcatlist,0,7,true);if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$sub): $mod = ($i % 2 );++$i;?><li> <a href="<?php echo U('List/index','id='.$sub['fcid']);?>" class="list-group-item"><span style="margin-left:30px;"><?php echo ($sub["fcname"]); ?></span><span class="fa fa-caret-right pull-right"></span></a></li><?php endforeach; endif; else: echo "" ;endif; ?>
      <div class="icon">
       	嗨
       </div>
     </ul> 
    </div> 
 <!-- 全局左侧导航菜单 -->

<div class="h10"></div>







 <!-- 导航菜单结束 -->
 <!-- 首页轮播图开始 -->
 <div class="Imgshow w120">
 <script type="text/javascript" src="__ROOT__/Public/js/unslider.min.js"></script>
<style>
ul, ol { padding: 0;}
.banner { position: relative; overflow: auto; text-align: center;}
.banner li { list-style: none; }
.banner ul li { float: left; }
#b04 { width: 1200px;}
#b04 .dots { position: absolute; left: 0; right: 0; bottom: 20px;}
#b04 .dots li 
{ 
    display: inline-block; 
    width: 10px; 
    height: 10px; 
    margin: 0 4px; 
    text-indent: -999em; 
    border: 2px solid #fff; 
    border-radius: 6px; 
    cursor: pointer; 
    opacity: .4; 
    -webkit-transition: background .5s, opacity .5s; 
    -moz-transition: background .5s, opacity .5s; 
    transition: background .5s, opacity .5s;
}
#b04 .dots li.active 
{
    background: #fff;
    opacity: 1;
}
#b04 .arrow { position: absolute; top: 200px;}
#b04 #al { left: 15px;}
#b04 #ar { right: 15px;}
#b04 .dots li{width:40px; height:10px;}
#b04 .dots li.active{opacity:0.8}
</style>
<script>
$(document).ready(function(e) {
    var unslider04 = $('#b04').unslider({
        dots: true
    }),
    data04 = unslider04.data('unslider');
     
    $('.unslider-arrow04').click(function() {
        var fn = this.className.split(' ')[1];
        data04[fn]();
    });
});
</script>
<div class="banner" id="b04">
    <ul>
    <?php if(is_array($adlist)): $i = 0; $__LIST__ = $adlist;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$adlist): $mod = ($i % 2 );++$i;?><li onclick="location.href='<?php echo ($adlist["link"]); ?>'"><img src="<?php echo ($adlist["linkpic"]); ?>" alt="<?php echo ($adlist["name"]); ?>" width="1200" height="480" ></li><?php endforeach; endif; else: echo "" ;endif; ?>
    </ul>
    <a href="javascript:void(0);" class="unslider-arrow04 prev"><img class="arrow" id="al" src="<?php echo (TEMPS); ?>/images/banner/arrowl.png" alt="prev" width="20" height="35"></a>
    <a href="javascript:void(0);" class="unslider-arrow04 next"><img class="arrow" id="ar" src="<?php echo (TEMPS); ?>/images/banner/arrowr.png" alt="next" width="20" height="37"></a>
</div>
 </div>
 <!-- 轮播结束 -->
 <!-- 按照品类分类 -->
 <div class="h10"></div>
 <div class="over w120 bck">
 	<div class="title">
 		<span class='left'>按品类分:</span>
 		<div class="siz left">
 		<?php if(is_array($tag)): $i = 0; $__LIST__ = $tag;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$tag): $mod = ($i % 2 );++$i;?><button class="btn btn-default btn-xs" type="button">
			  <?php echo ($tag["tagname"]); ?> <span class="badge"><?php echo ($tag["id"]); ?></span>
			</button><?php endforeach; endif; else: echo "" ;endif; ?>
 		</div>
 	</div>
 </div>
 <!-- 分类结束 -->
 <!-- 列表开始01 -->
 <div class="food w120">
 	<ul>
 	<?php if(is_array($foodlist)): $i = 0; $__LIST__ = $foodlist;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$foodlist): $mod = ($i % 2 );++$i;?><li onclick="location.href='<?php echo U('Product/index','id='.$foodlist['fid']);?>'">
 			<div class="bk"></div>
 			<div class="info">
 				<div class="money"><b>¥<?php echo ($foodlist["fprice"]); ?></b></div>
 				<div class="descript">
 					<?php echo (mb_substr($foodlist["fcontent"],0,35,'utf-8')); ?>...
 				</div>
 				<div class="stitle">
 					<?php echo ($foodlist["fname"]); ?>
 				</div>
 			</div>
 			<img src="__ROOT__<?php echo ($foodlist["fpic"]); ?>" alt="">
 		</li><?php endforeach; endif; else: echo "" ;endif; ?>
 	</ul>
 </div>
 <!-- 结束 -->
 <!-- 任性一点 -->
 <div class="h10"></div>
 <div class="over w120 bck">
 	<div class="title">
 		<span class='left'>我的任性小餐:</span>
 		<div class="siz left">
 			<?php if(is_array($tags)): $i = 0; $__LIST__ = $tags;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$tags): $mod = ($i % 2 );++$i;?><button class="btn btn-default btn-xs" type="button">
			  <?php echo ($tags["tagname"]); ?> <span class="badge"><?php echo ($tags["id"]); ?></span>
			</button><?php endforeach; endif; else: echo "" ;endif; ?>
 		</div>
 	</div>
 </div>
 <!-- 任性结束 -->
 <div class="h10"></div>
 <!-- headfly -->
<div class="ps w120" style="position:relative;overflow:hidden">
 <link rel="stylesheet" href="__ROOT__/public/headfly/css/style.css" type="text/css" media="screen"/>
        <style>
            .titless{
                width:500px;
                height:152px;
                position:absolute;
                top:0px;
                left:0px;
                background:transparent url(title.png) no-repeat top left;
            }
            a.back{
                background:transparent url(back.png) no-repeat top left;
                position:fixed;
                width:150px;
                height:27px;
                outline:none;
                bottom:0px;
                left:0px;
            }
            #content{
                margin:0 auto;
            }
            .reference{
                clear:both;
                top:300px;
                left:0px;
                position:absolute;
                text-align:right;
                width:400px;
                padding:20px;
                background-color:#fff;
                -moz-box-shadow:1px 3px 15px #ddd;
                -webkit-box-shadow:1px 3px 15px #ddd;
                box-shadow:1px 3px 15px #ddd;
            }
            .reference p a{
                text-transform:uppercase;
                text-shadow:1px 1px 1px #fff;
                color:#666;
                text-decoration:none;
                font-size:10px;
            }
            .reference p a:hover{
                color:#333;
            }
			ul.accordion{
				overflow:hidden!important;
			}

        </style>
        <div id="content">
            <div class="titless"></div>
            <div class="reference">
                <p><a href="javascript:;">Image 1: Michelle Meiklejohn / FreeDigitalPhotos.net</a></p>
                <p><a href="javascript:;">Image 2: Luigi Diamanti / FreeDigitalPhotos.net</a></p>
                <p><a href="javascript:;">Image 3: Tina Phillips / FreeDigitalPhotos.net</a></p>
                <p><a href="javascript:;">Image 4: Ahmet Guler / FreeDigitalPhotos.net</a></p>
            </div>


            <ul class="accordion" id="accordion">
            <?php if(is_array($fly)): $i = 0; $__LIST__ = $fly;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$fly): $mod = ($i % 2 );++$i;?><li class="bg1" style="background:url('__ROOT__/<?php echo ($fly["fpic"]); ?>');">
                    <div class="heading"><?php echo ($fly["fname"]); ?></div>
                    <div class="bgDescription"></div>
                    <div class="description">
                        <a href="<?php echo U('Product/index','id='.$fly['fid']);?>"><h2><?php echo ($fly["fname"]); ?></h2></a>
                        <p><?php echo ($fly["fcontent"]); ?>.</p>
                        <a href="#">Look &rarr;</a>
                    </div>
                </li><?php endforeach; endif; else: echo "" ;endif; ?>
            </ul>
        </div>

        <!-- The JavaScript -->
        <script type="text/javascript">
            $(function() {
                $('#accordion > li').hover(
                    function () {
                        var $this = $(this);
                        $this.stop().animate({'width':'480px'},500);
                        $('.heading',$this).stop(true,true).fadeOut();
                        $('.bgDescription',$this).stop(true,true).slideDown(500);
                        $('.description',$this).stop(true,true).fadeIn();
                    },
                    function () {
                        var $this = $(this);
                        $this.stop().animate({'width':'115px'},1000);
                        $('.heading',$this).stop(true,true).fadeIn();
                        $('.description',$this).stop(true,true).fadeOut(500);
                        $('.bgDescription',$this).stop(true,true).slideUp(700);
                    }
                );
            });
        </script>
</div>
<!-- 第二次列表 -->
<!-- 任性一点 -->
 <div class="h10"></div>
 <div class="over w120 bck">
 	<div class="title">
 		<span class='left'>热门随机推荐:</span>
 		<div class="siz left">
 			<button class="btn btn-default btn-xs" type="button">
			  草莓味 <span class="badge">5</span>
			</button>
			<button class="btn btn-default btn-xs" type="button">
			  莎拉酱 <span class="badge">2</span>
			</button>
			<button class="btn btn-default btn-xs" type="button">
			  雨薇酱 <span class="badge">0</span>
			</button>
 		</div>
 	</div>
 </div>
 <!-- 任性结束 -->
 <!-- 列表开始02 -->
 <div class="food w120">
 	<ul>
 	<?php if(is_array($foodpage)): $i = 0; $__LIST__ = $foodpage;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$foodpage): $mod = ($i % 2 );++$i;?><li onclick="location.href='<?php echo U('Product/index','id='.$foodpage['fid']);?>'">
 			<div class="bk"></div>
 			<div class="info">
 				<div class="money"><b>¥<?php echo ($foodpage["fprice"]); ?></b></div>
 				<div class="descript">
 					<?php echo (mb_substr($foodpage["fcontent"],0,35,'utf-8')); ?>...
 				</div>
 				<div class="stitle">
 					<?php echo ($foodpage["fname"]); ?>
 				</div>
 			</div>
 			<img src="__ROOT__<?php echo ($foodpage["fpic"]); ?>" alt="">
 		</li><?php endforeach; endif; else: echo "" ;endif; ?>
 	</ul>
 </div>
 <!-- 结束 -->
 <!-- end -->
 <div class="h10"></div>
 <!-- 友情链接 -->
 <div id="link" class="w120">
 <a href="#">友情链接</a>:
 <a href="http://www.baidu.com" target="_blank">百度知道</a>
 <a href="http://sina.cn" target="_blank">新浪娱乐</a>
 <a href="http://he29.com" target="_blank">雅荷之家</a>
 <a href="http://tieba.baidu.com" target="_blank">百度贴吧</a>
 <a href="#">More</a>
 </div>
 <!-- 结束 -->
 <div class="footer">

<footer>
 	<div class="message">
 		<li>
 			<a href="<?php echo U('Article/s/',array('id'=>39));?>" target='_blank'>小店介绍</a>|
 			<a href="<?php echo U('Article/s/',array('id'=>37));?>" target='_blank'>关于我们</a>|
 			<a href="<?php echo U('Article/s/',array('id'=>40));?>" target='_blank'>加盟须知</a>|
 			<a href="<?php echo U('Article/s/',array('id'=>41));?>" target='_blank'>小店招聘</a>
 		</li>
 		<li>
 			<a href='http://weibo.com/u/2526298841' target='_blank'><span> @2014  甜蜜爱恋  All rights reserved</span> </a>
 		</li>
 		<li>
 			<span> Weicake | 赣ICP备11007040号-4</span>
 		</li>
 	</div>
 </footer>
    
	


	
<!-- Modal -->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
        <h4 class="modal-title" id="myModalLabel">提示</h4>
      </div>
      <div class="modal-body">
       
   <p style="text-align:center">   
   <a href="<?php echo U('Public/register/');?>" class="btn btn-danger">注册成为会员更多优惠</a>
　　　　　
   <a href="<?php echo U('Cart/index/');?>" class="btn btn-default">不注册直接下单</a>

  </p>
  



      </div>
       
	 
    </div><!-- /.modal-content -->
  </div><!-- /.modal-dialog -->
</div><!-- /.modal -->	
 <script src="__ROOT__/Public/js/simpleCart.min.js"></script> 
	 <link href="<?php echo (TEMPS); ?>/css/cart-min.css" rel="stylesheet" type="text/css"/>
<script>

simpleCart({
 	currency: "JPY",
	shippingQuantityRate: 0,
	shippingTotalRate: 0,
	 shippingFlatRate: <?php echo ($pspay); ?>,
	cartColumns: [
{ attr: "name" , label: "商品" } ,
//{ attr: "price" , label: "单价", view: 'currency' } ,
{ view: "decrement" , label: false , text: "-" } ,
{ attr: "quantity" , label: "数量" } ,
{ view: "increment" , label: false , text: "+" } ,
{ attr: "total" , label: "总价", view: 'currency' } ,
//{ view: "remove" ,  label: ''}
]
  });
  
 



</script>
 <script>
   
    $("div[role='dialog']").on("show.bs.modal", function() {  
        // 具体css样式调整  
        $(this).css({  
            "display": "block",  
            "margin-top": function() {  
                return ($(this).height() / 3);  
            }  
        });  
    });  

 </script>		
	
		<script type="text/javascript">

	
	
simpleCart.bind( "update" , function(){

 if(simpleCart.total()<=0){
 $("#cartSubmit").hide();
 $("#cartIsEmpty").show();
 $("#cartCha").hide();
 }
 else{
	 if( <?php echo ($startpay); ?>- simpleCart.total() <=0){
      $("#cartSubmit").show();
	$("#cartIsEmpty").hide();
	  $("#cartCha").hide();
    } else {
	$("#cartCha").show();
	$("#cartSubmit").hide();
    $("#cartIsEmpty").hide();
   var showimg = <?php echo ($startpay); ?>- simpleCart.total();
$("#cha").text(showimg);
    }}
 
});



	
	 </script>
	
	
	
	
	

<div class="container navbar-fixed-bottom visible-xs" style="background-color:#FFF;">
  <div class="row ">
  
       <div class="col-md-3 col-xs-3"><a class="icon-btn" href="<?php echo U('Index/index/');?>">
								<i class="fa fa-home"></i>
								<div>首页</div>
								
							</a></div>
	 <div class=" col-xs-3">
	 <div class="btn-group dropup">
	 <a class="icon-btn dropdown-toggle" data-toggle="dropdown" >
								<i class="fa fa-th-large"></i>
								<div>菜品分类</div>
								
							</a>
							<ul class="dropdown-menu" style="min-width:245px;" role="menu">
							<?php if(is_array($foodcatlist)): $i = 0; $__LIST__ = $foodcatlist;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?><li><a class="btn" href="<?php echo U('index/flist/','id='.$vo['fcid']);?>"><?php echo ($vo["fcname"]); ?></a></li>
							 <li class="divider"></li><?php endforeach; endif; else: echo "" ;endif; ?>
							
                             </ul>
							</div>
							
							</div>
	<div class="col-md-3 col-xs-3">
	 <div class="btn-group dropup">
	 <a class="icon-btn" href="<?php echo U('Member/index/');?>">
								<i class="fa fa-user"></i>
								<div>我的订单</div>
								
							</a>
						
							</div>
							
							</div>
	 
	 
	 
	
	 <div class="col-md-3 col-xs-3">
	 <a class="icon-btn" href="<?php echo U('Cart/index/');?>">
								<i class="fa fa-shopping-cart"></i>
								<div>购物车</div>
								<span class="badge" > <span class="simpleCart_quantity "></span>
		</span>
							</a>
							
	 </div>
  
   <!-- <div class="col-md-3 col-xs-3"><a class="icon-btn" href="<?php echo U('Home/map/');?>">
								<i class="fa fa-map-marker"></i>
								<div>店铺位置</div>
								
							</a></div>-->
  </div>

</div>

 <!-- 结束 -->
<!-- 购物车模块 -->
</body>
</html>

<script type="text/javascript">
	$(document).ready(function() {
		$('.food ul li').hover(function() {
			$(this).find('.bk').fadeIn(50);
			$(this).find('.info').stop().animate({bottom: '45px'}, 500);
		}, function() {
			$(this).find('.bk').hide();
			$(this).find('.info').stop().animate({bottom: '-105px'}, 500);
		});
	});
</script>